package com.ktgj.service.service;

import java.math.BigDecimal;
import java.util.List;
import java.util.Map;

import com.ktgj.service.domain.*;
import com.ktgj.service.domain.vo.*;

import javax.servlet.http.HttpServletRequest;

/**
 * VIP通道订单
Service接口
 * 
 * @author ruoyi
 * @date 2021-09-03
 */
public interface IOrderVipchannelService 
{
    /**
     * 查询VIP通道订单

     * 
     * @param ordervipchannelId VIP通道订单
ID
     * @return VIP通道订单

     */
    public OrderVipchannel selectOrderVipchannelById(Long ordervipchannelId);

    /**
     * 查询VIP通道订单
列表
     * 
     * @param orderVipchannel VIP通道订单

     * @return VIP通道订单
集合
     */
    public List<OrderVipchannel> selectOrderVipchannelList(OrderVipchannel orderVipchannel);

    /**
     * 新增VIP通道订单

     * 
     * @param orderVipchannel VIP通道订单

     * @return 结果
     */
    public int insertOrderVipchannel(OrderVipchannel orderVipchannel);

    /**
     * 修改VIP通道订单

     * 
     * @param orderVipchannel VIP通道订单

     * @return 结果
     */
    public int updateOrderVipchannel(OrderVipchannel orderVipchannel);

    /**
     * 批量删除VIP通道订单

     * 
     * @param ordervipchannelIds 需要删除的VIP通道订单
ID
     * @return 结果
     */
    public int deleteOrderVipchannelByIds(Long[] ordervipchannelIds);

    /**
     * 删除VIP通道订单
信息
     * 
     * @param ordervipchannelId VIP通道订单
ID
     * @return 结果
     */
    public int deleteOrderVipchannelById(Long ordervipchannelId);

    /**
     *
     * @param ordervipchannelId 快速通道详情
     * @return
     */
    public List<OrderVipchannel> select(Long ordervipchannelId);

    /**
     * VIP通道填写订单
     * @param token
     * @param request
     * @return
     */
    public VipchannelFillOrder serviceInformation(String token, FillOrderRequest request);

    /**
     * VIP通道订单生成
     *
     * @param token     请求头
     * @param vipchannelId   VIP通道id
     * @param paymentAmount     应付金额
     * @param points      积分
     * @param couponId    优惠卷id
     * @param totalsalePrice 订单总金额
     * @param usedDeposit 预留款
     * @param contactName 联系人姓名
     * @param contactPhone 联系人电话
     * @return
     */
    public String saveOrder(String token, Long vipchannelId, String arrivalDate,
                          Long peopleNumber, BigDecimal paymentAmount, BigDecimal points, Long couponId,
                          BigDecimal totalsalePrice, BigDecimal usedDeposit, String contactName, String contactPhone,
                          String usePoint, String useDeposits) throws Exception;

    /**
     * VIP通道订单收银台
     * @param customerId
     * @return
     */
    public VipchannelCashier queryByPayOrder(Long customerId, Long orderNumber, String businessType) throws Exception;

    /**
     * 查询当前用户全部订单
     * */
    public OrderVo selectOrderVipchannelByCustomerIdAndOrdervipchannelId(Long customerId, String type) throws Exception;

    /**
     * 支付成功页面
     * @param ordervipchannelId
     * @return
     */
    public Map<String, Object> selectOrderVipchannelNumber(Long ordervipchannelId);

    public Map<String, Object> queryVipchannelTrip(Long ordervipchannelId);

    /**
     * 查询订单行程
     * @param orderNumber
     * @return
     */
    public Map<String, Object> queryVipchannelTripByOrderNumber(Long orderNumber);

    public Map<String, Object> selectItinerary(Long ordervipchannelId);

    /**
     * 首页-黄金会员-进行中/已使用
     * @param customerId
     * @return
     */
    public List<Vipchannel> selectOrderVipchannelByStatus(Long customerId);

    /**
     * 定制行程-单程
     * @param customerId
     * @return
     */
    public OrderVipchannel queryItinerary(Long customerId);

    /**
     * 微信小程序支付
     * @param openId
     * @param orderNumber
     * @return
     */
    public Map<String, Object> wechatPay(String openId, Long orderNumber, BigDecimal amount, String type) throws Exception;

    /**
     * 修改VIP通道订单

     *
     * @param orderVipchannel VIP通道订单

     * @return 结果
     */
    public int updateByOrderNumber(OrderVipchannel orderVipchannel);

    /**
     * 查询vip通道订单列表
     * */
    public List<OrderVipchannel> selectOrderVipchannel(Long customerId, String type) throws Exception;

    /**
     * 条件查询vip通道订单列表
     * */
    public List<OrderVipchannel> selectVipchannelOrederListVo(VipchannelOrederParameterVo vipchannelOrederParameterVo);

    /**
     * vip通道订单详细
     * */
    public OrderViphallDetailsVo selectVipchannelOrederListDetailsVo(Long ordervipchannelId, String orderNum) throws Exception;

    /**
     * vip通道行程订单
     * */
    public JourneyOrderViphallVo journeyOrderVipchannelVo(Long ordervipchannelId);

    /**
     * VIP通道退单
     * */
    public int chargebackVipchannel(Long ordervipchannelId);
    /**
     * 订单号查数据
     * */
    public OrderViphallDetailsVo queryByOrderNumber(Long orderNumber)throws Exception;

    /**
     * 订单号获取vip通道订单信息
     * */
    public OrderVipchannel orderVipchannel(String orderNum);
}
